using UniversalAdminSystem.Application.SystemSettings.DTOs;
using UniversalAdminSystem.Application.Common.Results;

namespace UniversalAdminSystem.Application.SystemSettings.Interfaces;

public interface ISystemSettingAppService
{
    /// <summary>
    /// 获取所有系统设置
    /// </summary>
    Task<Result<IEnumerable<SystemSettingDto>>> GetAllSettingsAsync();

    /// <summary>
    /// 根据键获取系统设置
    /// </summary>
    Task<Result<SystemSettingDto?>> GetSettingByKeyAsync(string key);

    /// <summary>
    /// 根据组获取系统设置
    /// </summary>
    Task<Result<IEnumerable<SystemSettingDto>>> GetSettingsByGroupAsync(string group);

    /// <summary>
    /// 创建系统设置
    /// </summary>
    Task<Result<SystemSettingDto>> CreateSettingAsync(SystemSettingCreateDto createDto);

    /// <summary>
    /// 更新系统设置
    /// </summary>
    Task<Result<SystemSettingDto>> UpdateSettingAsync(Guid id, SystemSettingUpdateDto updateDto);

    /// <summary>
    /// 删除系统设置
    /// </summary>
    Task<Result> DeleteSettingAsync(Guid id);
} 